package main

import (
	"fmt"
	"reflect"
)

type Persons struct {
	Name string `json:"name" info:"name"`
	Age  int    `json:"age"`
	Sex  int    `json:"sex" info:"sex"`
}

func findTag(str interface{}) {
	t := reflect.TypeOf(str).Elem()

	for i := 0; i < t.NumField(); i++ {
		tag := t.Field(i).Tag.Get("info")
		fmt.Println(tag)
	}
}
func main() {
	var person Persons

	findTag(&person)
}
